<%@ page contentType="text/html; charset=utf-8" language="java" import="java.sql.*"%>
<html>
<body>
<table border="1">
<%
if(session.getAttribute("userName") != null) {
out.println("查询结果：");
out.println("身份证号：" + request.getParameter("id_card"));
   Class.forName("com.mysql.jdbc.Driver").newInstance();
   Connection con=java.sql.DriverManager.getConnection("jdbc:mysql://192.168.1.99:3306/fwy_hr_shebao?useUnicode=true&amp;characterEncoding=utf8&amp;autoReconnect=true","fwy_hr_shebao","fwy_hr_shebao");
   Statement stmt=con.createStatement();
    ResultSet rst=stmt.executeQuery("select * from t_sb_user where id_card='" + request.getParameter("id_card") + "'");
    while(rst.next())
    {
    	String url1="http://192.168.1.99"+rst.getString("id_card_img").substring(0, rst.getString("id_card_img").indexOf("#"));
    	String url2="http://192.168.1.99"+rst.getString("id_card_img").substring(rst.getString("id_card_img").indexOf("#")+1, rst.getString("id_card_img").length());
        out.println("<tr>");
        out.println("<td><a href='" + url1 +"'>" + url1 +"</a></td>");
        out.println("</tr>");
        out.println("<tr>");
        out.println("<td><a href='" + url2 +"'>" + url2 +"</a></td>");
        out.println("</tr>");
    }
    rst.close();
    stmt.close();
    con.close();
} else {
	out.println("未登录！");
}

%>
</table>
</body>
</html>